/**
 * ===========================================
 * Project: gamehistory-service
 * ===========================================
 * Package: com.cyou.gamehistory.util
 * 
 * Copyright (c) 2012, CYOU All Rights Reserved.
 * ===========================================
 */
package com.cyou.gamehistory.util;

/**
 * <p>MemcachedObjectType</p>
 * <p>
 * Description:
 * 统一定义Memcached中存储的各种对象的Key前缀和超时时间.
 * </p>
 *
 * @since 1.0
 * @version 1.0 2012-12-11
 * @author zhangxingkai
 */
public enum MemcachedObjectType {
	
	AppInfo("appInfo:", 60 * 60 * 24), // expiredTime: 1 day
	GameHistoryFeed("gameHistoryFeed:", 60 * 60 * 1); // expiredTime: 1 hour
	
	private String prefix;
	private int expiredTime;

	MemcachedObjectType(String prefix, int expiredTime) {
		this.prefix = prefix;
		this.expiredTime = expiredTime;
	}

	public String getPrefix() {
		return prefix;
	}

	public int getExpiredTime() {
		return expiredTime;
	}

}
